package com.osiatis.epitech.fragments;

import java.util.ArrayList;
import java.util.List;

import com.osiatis.epitech.R;
import com.osiatis.epitech.UserListActivity;

import android.support.v4.app.Fragment;
import android.support.v4.app.ListFragment;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ArrayAdapter;
import android.widget.ListView;
import android.widget.TextView;

public class UserListFragment extends ListFragment {
	
	private List<String> userLogins;

	@Override
	public void onActivityCreated(Bundle savedInstanceState) {
		
        setListAdapter(new ArrayAdapter<String>(getActivity(),
        		R.layout.simple_textview, userLogins));

		// TODO Auto-generated method stub
		super.onActivityCreated(savedInstanceState);
	}

	@Override
	public void onListItemClick(ListView l, View v, int position, long id) {
		getActivity().getActionBar().selectTab(getActivity().getActionBar().getTabAt(1));
	}
	
	public List<String> getUserLogins() {
		return userLogins;
	}

	public void setUserLogins(List<String> userLogins) {
		this.userLogins = userLogins;
	}
	

}
